

a="a"
b = [1,2]
arr = [b[i] for i in range(2) if b[i] == 1]
print(arr)